package org.qiyu.live.user.interfaces;

import org.qiyu.live.user.dto.UserDTO;

import java.util.List;
import java.util.Map;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: sfx
 * Date: 2023-09-12
 * Time: 17:12
 */
public interface IUserRpc {
    String test();
    /**
     * 根据userId查询到userInfo
     * @param userId 用户id
     * @return 返回UserDTO对象
     */
    UserDTO getUserInfo(Long userId);

    /**
     * 更新UserDTO对象
     * @param userDTO userDTO对象
     * @return 返回是否更新成功
     */
    boolean updateUserInfo(UserDTO userDTO);

    /**
     * 插入单个UserDTO对象
     * @param userDTO userDTO对象
     * @return
     */
    boolean insertOne(UserDTO userDTO);

    /**
     * 批量查询userInfo
     * @param userIdList 查询多个userId
     * @return 返回Map对象
     */
    Map<Long,UserDTO> batchQueryUserInfo(List<Long> userIdList);
}